package day03.`match`

import scala.util.Random

object MatchStr {
  def main(args: Array[String]): Unit = {
    val arr = Array("zhangsan","lisi","wangwu","zhaoliu","")
    val name = arr(Random.nextInt(arr.length))

    name match {
      case "zhangsan" => println("张三")
      case "lisi" => println("李四")
      case "wangwu" => println("王五")
      case "zhaoliu" => println("赵六")
      case _ => println("Nothing")
    }
  }
}
